<%@ page contentType="text/html;charset=UTF-8" language="java" isELIgnored="false" pageEncoding="UTF-8" %>
<%@ taglib prefix="c" uri="http://java.sun.com/jstl/core_rt" %>
<%@ taglib prefix="fmt" uri="http://java.sun.com/jstl/fmt_rt" %>

<html>
<head>
    <title>登录页</title>
    <%--echart线图、柱状图、饼图等各种图型库 cdn--%>
    <script type="text/javascript" src="https://cdnjs.cloudflare.com/ajax/libs/echarts/5.4.3/echarts.min.js"></script>
    <%--jquery cdn--%>
    <script type="text/javascript" src="https://cdn.bootcdn.net/ajax/libs/jquery/3.6.1/jquery.js"></script>
</head>
<body>
${nickName}

<img src="${avatarUrl}">


<form action="/list.do">

    学生 <input name="studentName"><br>
    宿舍 <input name="roomName"><br>
    楼号 <input name="apartmentName"><br>
     <input type="submit" value="查询"><br>
    <a href="/addPage.do">添加</a>

    <table>
        <tr>
            <td>楼号</td>
            <td>宿舍号</td>
            <td>图片</td>
            <td>学生</td>
            <td>入住时间</td>
        </tr>

        <c:forEach items="${list}" var="l">

            <tr>
                <td>${l.apartmentName}</td>
                <td>${l.roomName}</td>
                <td><img src="${l.pic}" style="height: 50px;width: 50px"></td>
                <td>${l.studentName}</td>
                <td>${l.createTime}</td>
            </tr>
        </c:forEach>
    </table>

</form>


</body>
</html>